#define  _CRT_SECURE_NO_WARNINGS 1
#include <iostream>
using namespace std;

bool isPalindrome(string s) {
	
	string str;
	for (auto e : s)
	{
		if (isalnum(e))
			//if((e >= 'A' && e <= 'Z') || (e >= 'a' && e <= 'z') || (e >= '0' && e <= '9'))
		{

			str += tolower(e);
		}
	}
	int end = str.size() - 1;
	int begin = 0;
	while (begin < end)
	{
		if (str[begin] != str[end])
			return false;
		else
		{
			++begin;
			--end;
		}
	}
	return true;
}

int main()
{
	bool ret = isPalindrome("A man, a plan, a canal: Panama");
	return 0;
}